<%--
  @author Duminda Dharmakeerthi
  @author Supun Nimesh Karunathilaka
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<script src="${pageContext.request.contextPath}/js/printer.js" type="text/javascript"></script>
<%--<link rel="stylesheet" href="${pageContext.request.contextPath}/css/printDetailForm.css" media="print"/>--%>


<script language="javascript">
    function showAcquiredStatus() {
        $('#acquired').show();
    }

    function hideAcquiredStatus() {
        $('#acquired').hide();
    }
    function showEncroachment() {
        $('#encroachmentDescription').show();
    }

    function hideEncroachment() {
        $('#encroachmentDescription').hide();
    }
</script>

<s:include value="../../printCaller.jsp"/>

<div id="printDivId" class="form-outer">
    <h2><s:label value="%{getText('detailed_land_info.label')}"/> - <s:label
            value="%{getText('vesting_order.label')}"/></h2>
    <hr/>
    <s:if test="hasActionErrors() || hasActionMessages()">
        <div id="message-box" class="message-box">
            <div class="action-msg"><s:actionmessage/></div>
            <div class="action-err"><s:actionerror/></div>
        </div>
    </s:if>
    <s:form id="gov-land-detail-info-form" method="POST">
        <div id="tabs">
            <%--<div id="printbtn" class="form-button-div right-align">
                    &lt;%&ndash;<input type="button" value="Print" id="print"  class="print-btn">&ndash;%&gt;
                <input type="button" value="Print" onclick="printPage();">
                <input class="printButton" type="button" value="Back" onclick="goBack();">

            </div>--%>


            <div id="land-details">
                <h3><s:label value="%{getText('land_details.label')}"/></h3>
                <table class="width-100">

                    <s:include value="../landDetailsReport.jsp"/>

                </table>
                <hr/>
            </div>


            <div id="vesting-order-details">
                <h3><s:label
                        value="%{getText('vesting_order_details.label')}"/></h3>
                <table class="width-100">
                    <tr>
                        <td><s:label value="%{getText('vesting_order_no.label')}"/></td>
                        <td><s:label name="alienation.referenceNo"/></td>
                        <td><s:label value="%{getText('date_of_approved.label')}"/></td>
                        <td><s:label name="alienation.issueDate"/></td>
                    </tr>
                    <tr>
                        <td><s:label value="%{getText('folio_no.label')}"/></td>
                        <td><s:label id="folioNo" name="alienation.folioNumber"/></td>
                        <td><s:label value="%{getText('folio_date.label')}"/></td>
                        <td><s:label id="folioDate" name="alienation.folioDate" onclick="selectDate('folioDate')"/></td>
                    </tr>
                    <tr>
                        <td><s:label value="%{getText('folio_location.label')}"/></td>
                        <td colspan="3"><s:label id="folioLocation" name="alienation.folioLocation" rows="1"
                                                 cssClass="width-595-px"/></td>
                    </tr>

                    <tr id="acquired">
                        <td><s:label value="%{getText('if_acquired_purpose.label')}"/></td>
                        <td colspan="3"><s:label
                                name="alienation.acquiredDescription"
                                cssClass="width-500-px"/></td>
                    </tr>

                    <tr id="encroachmentDescription">
                        <td><s:label value="%{getText('encroachment_description.label')}"/></td>
                        <td colspan="3"><s:label name="alienation.encroachmentDescription"
                                                 cssClass="width-500-px"/></td>
                    </tr>
                    <tr>
                        <td><s:label value="%{getText('developed_status.label')}"/></td>
                        <td colspan="3" class="left-align"><s:label
                                name="alienation.developmentState"
                                cssClass="width-500-px"/></td>
                    </tr>
                    <tr>
                        <td><s:label value="%{getText('comment_about_alienation.label')}"/></td>
                        <td colspan="3"><s:label name="alienation.alienationComment" cssClass="width-595-px"/></td>
                    </tr>
                </table>
                <hr/>
            </div>
            <div id="institute-details">
                <h3><s:label value="%{getText('institute_details.label')}"/></h3>
                <table class="width-100">
                    <tr>
                        <td><s:label value="%{getText('name_of_client.label')}"/></td>
                        <td colspan="3">
                            <s:label name="alienation.holder.name" cssClass="width-610-px"/>
                        </td>
                    </tr>
                    <tr>
                        <td><s:label value="%{getText('address_of_client.label')}"/></td>
                        <td colspan="3"><s:label name="alienation.holder.contacts.address"
                                                 cssClass="width-610-px"/></td>
                    </tr>
                </table>
                <hr/>
            </div>
            <s:if test="land.occupiers.size() >0">
            <div id="occupier-details">
                <h3><s:label value="%{getText('occupier_details.label')}"/></h3>
                <table class="width-100">
                    <s:include value="../occupierDetailsReport.jsp"/>
                </table>
                <hr/>
            </div>

        </s:if>


        </div>
    </s:form>
</div>
<s:hidden id="pls_enter_reference_no" value="%{getText('pls_enter_reference_no')}"/>
<s:hidden id="pls_enter_name_of_the_land" value="%{getText('pls_enter_name_of_the_land')}"/>
<s:hidden id="pls_enter_plan_no" value="%{getText('pls_enter_plan_no')}"/>
<s:hidden id="pls_enter_lot_no" value="%{getText('pls_enter_lot_no')}"/>
<s:hidden id="pls_enter_valid_no" value="%{getText('pls_enter_valid_no')}"/>
<s:hidden id="pls_select_gn_division" value="%{getText('pls_select_gn_division')}"/>